package string;

import java.util.Scanner;

/**
 *  String replaceAll(String regex,String s):替换
 *  将当前字符串中满足正则表达式(regex)的部分给替换为指定字符串(s)
 */
public class ReplaceAllDemo {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入您要说的脏话:");
        String line = sc.next();
        line = line.replaceAll("(傻|逼|妈|爹|sha|bi|煞笔)","*");
        System.out.println(line);






















    }
}
